package com.shou.auth.model;

import jakarta.persistence.*;
import lombok.*;
import lombok.NoArgsConstructor;
import lombok.AllArgsConstructor;
import java.io.Serializable;

@Getter
@Setter
@NoArgsConstructor
@AllArgsConstructor
@Entity
@Table(name = "StaffInfo")
public class User implements Serializable {
    private static final long serialVersionUID = 1L;

    @Id
    @Column(name = "USERID", length = 50, nullable = false)
    private String userId;  // 用户ID

    @Column(name = "NAME", length = 50, nullable = false)
    private String name;  // 真实姓名

    @Column(name = "USERCODE", length = 20, nullable = false)
    private String userCode;  // 用户编号

    @Column(name = "SEX", length = 50, nullable = false)
    private String sex;  // 性别

    @Column(name = "DEPT", length = 50, nullable = false)
    private String dept;  // 部门

    @Column(name = "PWD", length = 20, nullable = false)
    private String password;  // 密码（数据库字段 PWD）

    @Column(name = "loginName", length = 40, nullable = false)
    private String loginName;  // 用户名

    @Column(name = "IDCARD", length = 18, nullable = false)
    private String idCard;  // 身份证号

    @Column(name = "HOMEADDRESS", length = 200, nullable = false)
    private String homeAddress;  // 居住地址

    @Column(name = "POSTCODE", length = 10, nullable = false)
    private String postCode;  // 邮编

    @Column(name = "EMAIL", length = 50, nullable = false)
    private String email;  // 电子邮箱

    @Column(name = "MOBILEPHONE", length = 20, nullable = false)
    private String mobilePhone;  // 手机号


    public String getUsername() {
        return name;
    }

    public void setUsername(String username) {
        this.name = username;
    }

    public String getPassword() {
        return password;
    }

    public void setPassword(String password) {
        this.password = password;
    }
    public String getUserId() {
        return userId;
    }
    
    public void setUserId(String userId) {
        this.userId = userId;
    }
    public String getLoginName() {
        return loginName;
    }
    
    public void setLoginName(String loginName) {
        this.loginName = loginName;
    }
    public String getName() {
        return name;
    }
    
    public void setName(String name) {
        this.name = name;
    }
    
    public String getUserCode() {
        return userCode;
    }
    
    public void setUserCode(String userCode) {
        this.userCode = userCode;
    }
    
    public String getSex() {
        return sex;
    }
    
    public void setSex(String sex) {
        this.sex = sex;
    }
    
    public String getDept() {
        return dept;
    }
    
    public void setDept(String dept) {
        this.dept = dept;
    }
    
    public String getIdCard() {
        return idCard;
    }
    
    public void setIdCard(String idCard) {
        this.idCard = idCard;
    }
    
    public String getHomeAddress() {
        return homeAddress;
    }
    
    public void setHomeAddress(String homeAddress) {
        this.homeAddress = homeAddress;
    }
    
    public String getPostCode() {
        return postCode;
    }
    
    public void setPostCode(String postCode) {
        this.postCode = postCode;
    }
    
    public String getEmail() {
        return email;
    }
    
    public void setEmail(String email) {
        this.email = email;
    }
    
    public String getMobilePhone() {
        return mobilePhone;
    }
    
    public void setMobilePhone(String mobilePhone) {
        this.mobilePhone = mobilePhone;
    }
    
}
